﻿
<%@ Page Language="C#" Theme="PAT_Theme" MasterPageFile="~/master/PAT.master" AutoEventWireup="true"  CodeFile="PatEmpresa.aspx.cs" Inherits="PatEmpresa" Title="PatEmpresa List" %>

<asp:Content ID="Content2" ContentPlaceHolderID="subHeaderContent" Runat="Server">Pat Empresa List</asp:Content>
<asp:Content ID="Content1" ContentPlaceHolderID="mainContent" Runat="Server">
		<data:GridViewSearchPanel ID="GridViewSearchPanel1" runat="server" GridViewControlID="GridView1" PersistenceMethod="Session" />
		<br />
		<data:EntityGridView ID="GridView1" runat="server"			
				AutoGenerateColumns="False"					
				OnSelectedIndexChanged="GridView1_SelectedIndexChanged"
				DataSourceID="PatEmpresaDataSource"
				DataKeyNames="IdEmpresa"
				AllowMultiColumnSorting="false"
				DefaultSortColumnName="" 
				DefaultSortDirection="Ascending"	
				ExcelExportFileName="Export_PatEmpresa.xls"  		
			>
			<Columns>
				<asp:CommandField ShowSelectButton="True" ShowEditButton="True" />				
				<asp:BoundField DataField="IdTipoIdentificacion" HeaderText="Id Tipo Identificacion" SortExpression="[ID_TIPO_IDENTIFICACION]"  />
				<asp:BoundField DataField="NumeroIdentificacion" HeaderText="Numero Identificacion" SortExpression="[NUMERO_IDENTIFICACION]"  />
				<asp:BoundField DataField="DigitoVerificacion" HeaderText="Digito Verificacion" SortExpression="[DIGITO_VERIFICACION]"  />
				<asp:BoundField DataField="RazonSocial" HeaderText="Razon Social" SortExpression="[RAZON_SOCIAL]"  />
				<asp:BoundField DataField="Sigla" HeaderText="Sigla" SortExpression="[SIGLA]"  />
				<asp:BoundField DataField="NombreComercial" HeaderText="Nombre Comercial" SortExpression="[NOMBRE_COMERCIAL]"  />
				<data:HyperLinkField HeaderText="Id Ubicacion Pais" DataNavigateUrlFormatString="PatUbicacionGeograficaEdit.aspx?IdUbicacion={0}" DataNavigateUrlFields="IdUbicacion" DataContainer="IdUbicacionPaisSource" DataTextField="Nombre" />
				<asp:BoundField DataField="IdRegimen" HeaderText="Id Regimen" SortExpression="[ID_REGIMEN]"  />
				<asp:BoundField DataField="Direccion" HeaderText="Direccion" SortExpression="[DIRECCION]"  />
				<asp:BoundField DataField="TelefonoFijo" HeaderText="Telefono Fijo" SortExpression="[TELEFONO_FIJO]"  />
				<asp:BoundField DataField="EMail" HeaderText="E Mail" SortExpression="[E_MAIL]"  />
				<data:BoundRadioButtonField DataField="Activo" HeaderText="Activo" SortExpression="[ACTIVO]"  />
			</Columns>
			<EmptyDataTemplate>
				<b>No PatEmpresa Found!</b>
			</EmptyDataTemplate>
		</data:EntityGridView>
		<br />
		<asp:Button runat="server" ID="btnPatEmpresa" OnClientClick="javascript:location.href='PatEmpresaEdit.aspx'; return false;" Text="Agregar Nuevo "></asp:Button>
		<data:PatEmpresaDataSource ID="PatEmpresaDataSource" runat="server"
			SelectMethod="GetPaged"
			EnablePaging="True"
			EnableSorting="True"
			EnableDeepLoad="True"
			>
			<DeepLoadProperties Method="IncludeChildren" Recursive="False">
	            <Types>
					<data:PatEmpresaProperty Name="PatUbicacionGeografica"/> 
					<%--<data:PatEmpresaProperty Name="PatEmpresaTallerCollection" />--%>
					<%--<data:PatEmpresaProperty Name="IdTallerPatTallerCollection_From_PatEmpresaTaller" />--%>
					<%--<data:PatEmpresaProperty Name="PatUsuarioCollection" />--%>
				</Types>
			</DeepLoadProperties>
			<Parameters>
				<data:CustomParameter Name="WhereClause" Value="" ConvertEmptyStringToNull="false" />
				<data:CustomParameter Name="OrderByClause" Value="" ConvertEmptyStringToNull="false" />
				<asp:ControlParameter Name="PageIndex" ControlID="GridView1" PropertyName="PageIndex" Type="Int32" />
				<asp:ControlParameter Name="PageSize" ControlID="GridView1" PropertyName="PageSize" Type="Int32" />
				<data:CustomParameter Name="RecordCount" Value="0" Type="Int32" />
			</Parameters>
		</data:PatEmpresaDataSource>
	    		
</asp:Content>



